Carbon


DMGetGDeviceByDisplayID

Header: Displays.h Carbon status: Supported

Obtains a handle for the video device with a specified display ID.

OSErr DMGetGDeviceByDisplayID (
    DisplayIDType displayID, 
    GDHandle *displayDevice, 
    Boolean failToMain
);
Parameter descriptions
displayID

The display ID for the video device whose handle you wish to obtain.

displayDevice

On return, a pointer to the handle to the GDevice structure for the video device specified by the displayID parameter.

failToMain

If true and there is no video device associated with the displayID parameter, on return the function sets displayDevice to a pointer to the handle for the video device for the main screen. If false and there is no video device associated with the displayID parameter, the function returns the kDMDisplayNotFoundErr result code.

function result

A result code.

SPECIAL CONSIDERATIONS

Because this function may move or purge memory blocks or access handles, you cannot call it at interrupt time.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)